package com.anlu.pattern.structrue.facade;

/**
 * Created with IntelliJ IDEA.
 *
 * @Author: anlu
 * @Date: 2021/05/19/16:51
 * @Description:
 */
public class OrderFacade {
    // 采摘服务
    private PickService pickService;
    // 打包服务
    private PackService packService;
    private SendService sendService;

    public OrderFacade() {
        this.pickService = new PickService();
        this.packService = new PackService();
        this.sendService = new SendService();
    }

    public void doOrder(){
        //采摘
        System.out.println("-----------------");
        pickService.doPick();
        //包装
        System.out.println("--------------");
        packService.doPack();
        //快递
        System.out.println("--------------");
        sendService.doSend();
    }
}
